//---------------------------------------------------------------------------

#ifndef GridFrameH
#define GridFrameH
//---------------------------------------------------------------------------
#include <Classes.hpp>
#include <Controls.hpp>
#include <StdCtrls.hpp>
#include <Forms.hpp>
#include "BaseFrame.h"
#include "cxClasses.hpp"
#include "dxBar.hpp"
#include "dxSkinBlack.hpp"
#include "dxSkinBlue.hpp"
#include "dxSkinBlueprint.hpp"
#include "dxSkinCaramel.hpp"
#include "dxSkinCoffee.hpp"
#include "dxSkinDarkRoom.hpp"
#include "dxSkinDarkSide.hpp"
#include "dxSkinDevExpressDarkStyle.hpp"
#include "dxSkinDevExpressStyle.hpp"
#include "dxSkinFoggy.hpp"
#include "dxSkinGlassOceans.hpp"
#include "dxSkinHighContrast.hpp"
#include "dxSkiniMaginary.hpp"
#include "dxSkinLilian.hpp"
#include "dxSkinLiquidSky.hpp"
#include "dxSkinLondonLiquidSky.hpp"
#include "dxSkinMcSkin.hpp"
#include "dxSkinMoneyTwins.hpp"
#include "dxSkinOffice2007Black.hpp"
#include "dxSkinOffice2007Blue.hpp"
#include "dxSkinOffice2007Green.hpp"
#include "dxSkinOffice2007Pink.hpp"
#include "dxSkinOffice2007Silver.hpp"
#include "dxSkinOffice2010Black.hpp"
#include "dxSkinOffice2010Blue.hpp"
#include "dxSkinOffice2010Silver.hpp"
#include "dxSkinPumpkin.hpp"
#include "dxSkinsCore.hpp"
#include "dxSkinsDefaultPainters.hpp"
#include "dxSkinsdxBarPainter.hpp"
#include "dxSkinSeven.hpp"
#include "dxSkinSevenClassic.hpp"
#include "dxSkinSharp.hpp"
#include "dxSkinSharpPlus.hpp"
#include "dxSkinSilver.hpp"
#include "dxSkinSpringTime.hpp"
#include "dxSkinStardust.hpp"
#include "dxSkinSummer2008.hpp"
#include "dxSkinTheAsphaltWorld.hpp"
#include "dxSkinValentine.hpp"
#include "dxSkinVS2010.hpp"
#include "dxSkinWhiteprint.hpp"
#include "dxSkinXmas2008Blue.hpp"
#include "cxControls.hpp"
#include "cxCustomData.hpp"
#include "cxData.hpp"
#include "cxDataStorage.hpp"
#include "cxDBData.hpp"
#include "cxEdit.hpp"
#include "cxFilter.hpp"
#include "cxGraphics.hpp"
#include "cxGrid.hpp"
#include "cxGridBandedTableView.hpp"
#include "cxGridCustomTableView.hpp"
#include "cxGridCustomView.hpp"
#include "cxGridDBBandedTableView.hpp"
#include "cxGridLevel.hpp"
#include "cxGridTableView.hpp"
#include "cxLookAndFeelPainters.hpp"
#include "cxLookAndFeels.hpp"
#include "cxNavigator.hpp"
#include "cxStyles.hpp"
#include "dxSkinscxPCPainter.hpp"
#include <DB.hpp>
#include "cxDrawTextUtils.hpp"
#include "dxBkgnd.hpp"
#include "dxPrnDev.hpp"
#include "dxPrnPg.hpp"
#include "dxPSCompsProvider.hpp"
#include "dxPSCore.hpp"
#include "dxPScxEditorProducers.hpp"
#include "dxPScxExtEditorProducers.hpp"
#include "dxPScxPageControlProducer.hpp"
#include "dxPSEdgePatterns.hpp"
#include "dxPSEngn.hpp"
#include "dxPSFillPatterns.hpp"
#include "dxPSGlbl.hpp"
#include "dxPSPDFExport.hpp"
#include "dxPSPDFExportCore.hpp"
#include "dxPSPrVwAdv.hpp"
#include "dxPSPrVwRibbon.hpp"
#include "dxPSPrVwStd.hpp"
#include "dxPSUtl.hpp"
#include "dxSkinsdxRibbonPainter.hpp"
#include "dxWrap.hpp"
#include "dxPScxGridLnk.hpp"
#include "InputQuery.cpp"
#include <cxGridExportLink.hpp>
#include <Dialogs.hpp>
#include "GlobalVariable.h"
#include "BaseCustomForm.h"
#include "Encddecd.hpp"
#include "cxGridCustomPopupMenu.hpp"
#include "cxGridPopupMenu.hpp"

//---------------------------------------------------------------------------
class TFGridFrame : public TFBaseFrame
{
__published:	// IDE-managed Components
	TdxBarManager *BarManager;
	TdxBar *CommonBar;
	TdxBar *CustomBar;
	TdxBarButton *dxBarButton1;
	TdxBarButton *dxBarButton2;
	TdxBarButton *dxBarButton3;
	TdxBarButton *dxBarButton4;
	TdxBarButton *dxBarButton5;
	TdxBarButton *dxBarButton6;
	TdxBarButton *dxBarButton7;
	TdxBarButton *dxBarButton8;
	TdxBarButton *dxBarButton9;
	TdxBarButton *dxBarButton10;
	TdxBarButton *dxBarButton11;
	TdxBarButton *dxBarButton12;
	TdxBarButton *dxBarButton13;
	TdxBarButton *dxBarButton14;
	TdxBarButton *dxBarButton15;
	TdxBarButton *dxBarButton16;
	TdxBarButton *dxBarButton17;
	TcxGridLevel *Level;
	TcxGrid *Grid;
	TcxGridDBBandedTableView *TableView;
	TdxBarButton *dxBarButton18;
	TdxComponentPrinter *Printer;
	TSaveDialog *SaveDialog;
	TdxBarCombo *GridFormat;
	TcxGridPopupMenu *cxGridPopupMenu;
	TdxBarButton *dxBarButton19;
	TdxBarButton *dxBarButton20;
	void __fastcall dxBarButton8Click(TObject *Sender);
	void __fastcall dxBarButton9Click(TObject *Sender);
	void __fastcall dxBarButton10Click(TObject *Sender);
	void __fastcall dxBarButton18Click(TObject *Sender);
	void __fastcall dxBarButton14Click(TObject *Sender);
	void __fastcall dxBarButton13Click(TObject *Sender);
	void __fastcall GridFormatChange(TObject *Sender);
	void __fastcall GridFormatDropDown(TObject *Sender);
	void __fastcall dxBarButton19Click(TObject *Sender);
	void __fastcall TableViewKeyDown(TObject *Sender, WORD &Key, TShiftState Shift);
	void __fastcall dxBarButton20Click(TObject *Sender);

private:	// User declarations
	map<String, String>StorageMap;

	String __fastcall GetStorageName(String name);
public:		// User declarations
	__fastcall TFGridFrame(TComponent* Owner);

	TdxGridReportLink *AGridLink;

	TUBaseCustomForm *ParentForm;

	int GridFormatIndex;

	int FocusedRecordIndex;

	bool ExecuteFormatChange;

	bool HasInitGridFormat;

	void __fastcall InitGridFormat();

	void __fastcall SetGridFormatIndex(int index);
};
//---------------------------------------------------------------------------
extern PACKAGE TFGridFrame *FGridFrame;
//---------------------------------------------------------------------------
#endif
